home *** CD-ROM | disk | FTP | other *** search
/ Netware Super Library / Netware Super Library.iso / pgm_tool / lu62 / calltpn.asm < prev    next >
Assembly Source File  |  1995-07-03  |  2KB  |  50 lines

  1. ;*********************************************************
  2. ;*                                                       *
  3. ;*     Call the user defined transaction program         *
  4. ;*                                                       *
  5. ;*  This subroutine calls the user defined transaction   *
  6. ;*  program and passes to it the CREATE_TP record.       *
  7. ;*                                                       *
  8. ;*                                                       *
  9. ;* CopyRight 1995. Nicholas Poljakov all rights reserved.*
  10. ;*                                                       *
  11. ;*********************************************************
  12. .MODEL LARGE
  13. .DATA
  14. .CODE
  15.          EXTRN  _tp_exit:dword
  16.          PUBLIC _calltpn
  17. _calltpn PROC
  18.          push  bp
  19.          mov   bp,sp
  20. ;
  21.          push  ds
  22. ;
  23.          mov   ax, [bp + 8]
  24.          mov   dx, [bp + 6]
  25.          cmp   ax, 0ffffh    ; check if the exit is not
  26.          jne   CallTP
  27.          cmp   dx, 0ffffh    ; available
  28.          jne   CallTP
  29.          mov   ax, 0         ; set the return code and then exit
  30.          mov   dx,084ch      ; rc. = 'tp_not_available_no_retry'
  31.          jmp   short CallTpExit
  32. CallTP:
  33.          mov   ds, ax
  34.          pushf
  35.          call  _tp_exit
  36. ;
  37. ;  Load the SENSE value from the CREATE_TP record.
  38. ;
  39.          mov   bx, dx
  40.          mov   ax, word ptr [bx + 20]  ; load the ax with value of sense
  41.          mov   dx, word ptr [bx + 22]  ; load the dx with value of sense
  42. ;
  43. CallTpExit:
  44.          pop   ds
  45. ;
  46.          pop   bp
  47.          ret
  48. _calltpn ENDP
  49.          END
  50.